﻿<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:vsm="clr-namespace:System.Windows;assembly=System.Windows"
    xmlns:d="clr-namespace:DeepEarth.BingMapsToolkit.Client.Controls"
    xmlns:d1="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d1"
    >


    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="/DeepEarth.BingMapsToolkit.Client.Common;component/Resources/CommonStyles.xaml" />
    </ResourceDictionary.MergedDictionaries>
    
    <!--<DataTemplate x:Key="EndPath">
    <Grid>
        <Path Stretch="Fill" StrokeThickness="1" StrokeLineJoin="Miter" Stroke="#FF000000" Data="F1 M700.58099,321.34064 C734.69,354.68164 733.41199,418.2294 699.23602,456.89941 L722.51898,456.89941 C732.60602,457.06741 744.37299,455.55441 744.36603,442.09241 C744.71002,434.03641 744.67798,355.97162 744.71002,338.82364 C744.54199,323.69363 732.77399,321.16684 722.18298,321.16684 C714.17798,321.16684 713.60901,321.34064 700.58099,321.34064 z" Width="14.616" Opacity="1" RenderTransformOrigin="0.5,0.5">
            <Path.Fill>
                <LinearGradientBrush  EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FF242424"/>
                    <GradientStop Color="#FF313131" Offset="1"/>
                    <GradientStop Color="#FF080808" Offset="0.55800002813339233"/>
                </LinearGradientBrush>
            </Path.Fill>
        </Path>
    </Grid>
    </DataTemplate>-->

    <Style TargetType="d:DirectionPanel">
    <Setter Property="Foreground" Value="White"/>
    <Setter Property="FontSize" Value="14"/>
    <Setter Property="Template">
        <Setter.Value>

            <ControlTemplate TargetType="d:DirectionPanel">
                <Grid x:Name="LayoutRoot" Width="488" Height="112" Opacity="0.82">
                    <VisualStateManager.VisualStateGroups>
                        <VisualStateGroup x:Name="CommonStates">
                            <VisualStateGroup.Transitions>
                                <VisualTransition GeneratedDuration="00:00:00.3000000"/>
                            </VisualStateGroup.Transitions>
                            <VisualState x:Name="MouseOver">
                                <Storyboard>
                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(UIElement.Opacity)">
                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                    </DoubleAnimationUsingKeyFrames>
                                </Storyboard>
                            </VisualState>
                            <VisualState x:Name="Normal">
                                <Storyboard/>
                            </VisualState>
                        </VisualStateGroup>
                    </VisualStateManager.VisualStateGroups>

                    <Border Margin="5,0,0,0" Background="#FF2B2B2B" BorderBrush="#FF000000" BorderThickness="1,1,1,1">
                        <Grid>
                        	<Grid Margin="0,0,0,0" RenderTransformOrigin="0.74,0.534">
                        		<StackPanel Margin="5,5,5,5" Orientation="Vertical" HorizontalAlignment="Left">
                        			<StackPanel Orientation="Horizontal" Margin="4,4,4,4">
                        				<ToggleButton x:Name="PART_FromToggleButton" Height="Auto" HorizontalAlignment="Right" Width="Auto" Style="{StaticResource ToggleButtonStyle}">
                        					<Image Source="/DeepEarth.BingMapsToolkit.Client.Controls.DirectionPanel;component/Images/Pin.png" Width="auto" Height="auto" Stretch="Uniform" />
                        				</ToggleButton>
                        				<TextBox Height="Auto" Width="400" Margin="4,0,0,0" x:Name="PART_tbFrom" Text="" Style="{StaticResource TextBoxStyle}" />
                        				<Button Height="Auto" HorizontalAlignment="Right" Width="Auto" x:Name="PART_sokFrom" Style="{StaticResource ButtonStyle}">
                        					<Image Source="/DeepEarth.BingMapsToolkit.Client.Controls.DirectionPanel;component/Images/search.png" Width="18" Height="18"/>
                        				</Button>
                        			</StackPanel>
                        			<StackPanel Orientation="Horizontal" Margin="4,4,4,4">
                        				<ToggleButton x:Name="PART_ToToggleButton" Height="Auto" HorizontalAlignment="Right" Width="Auto" Style="{StaticResource ToggleButtonStyle}">
                        					<Image Source="/DeepEarth.BingMapsToolkit.Client.Controls.DirectionPanel;component/Images/Pin.png" Width="auto" Height="auto" Stretch="Uniform"/> 
                        				</ToggleButton>
                        				<TextBox Height="Auto" Width="400" Margin="4,0,0,0" x:Name="PART_tbTo" Text="" Style="{StaticResource TextBoxStyle}" />
                        				<Button Height="Auto" HorizontalAlignment="Right" Width="Auto" x:Name="PART_sokTo" Style="{StaticResource ButtonStyle}">
                        					<Image Source="/DeepEarth.BingMapsToolkit.Client.Controls.DirectionPanel;component/Images/search.png"  Height="18" Width="18"/>
                                                        
                        				</Button>
                        			</StackPanel>
                        			<StackPanel Height="30" Margin="4,4,0,4" Width="463" Orientation="Horizontal" HorizontalAlignment="Left" VerticalAlignment="Bottom">
                        				<StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal">
                        					<Border Height="22" Width="202" CornerRadius="4" BorderThickness="2" BorderBrush="Black">
                        						<Grid>
                        							<RadioButton Style="{StaticResource RadioButtonStyle}" Width="96" Content="By Time" x:Name="PART_RadioTime" VerticalContentAlignment="Stretch" GroupName="TravelOpt" IsChecked="True" HorizontalAlignment="Left" d1:LayoutOverrides="Height"/>
                        							<RadioButton Style="{StaticResource RadioButtonStyle}" Content="By distance" x:Name="PART_RadioDistance" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" GroupName="TravelOpt" Margin="96,0,0,0" d1:LayoutOverrides="Height"/>
                        						</Grid>
                        					</Border>
                                            <Border Height="22" Width="202" CornerRadius="4" BorderThickness="2" BorderBrush="Black" Margin="4,0,0,0">
                                                <Grid>
                                                    <RadioButton Style="{StaticResource RadioButtonStyle}" Content="Driving" x:Name="PART_RadioDriving" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" GroupName="TravelMode" IsChecked="True" d1:LayoutOverrides="Height"/>
                                                    <RadioButton Style="{StaticResource RadioButtonStyle}" Margin="96,0,0,0" Content="Walking" x:Name="PART_RadioWalking" VerticalContentAlignment="Stretch" GroupName="TravelMode" HorizontalAlignment="Left" d1:LayoutOverrides="Height"/>
                                                </Grid>
                                            </Border>
                                        </StackPanel>
                                        
                                        
                        				<Button x:Name="PART_bClear" Margin="10,0,10,7" ToolTipService.ToolTip="Clear route and Addresses" Height="22" VerticalAlignment="Bottom" Style="{StaticResource ButtonStyle}" HorizontalAlignment="Right">
                        					<Image Source="/DeepEarth.BingMapsToolkit.Client.Controls.DirectionPanel;component/Images/Delete.png" Height="18" Width="18" />
                        				</Button>
                        			</StackPanel>
                        		</StackPanel>
                        	</Grid>
                        </Grid>
                    </Border>

                    <ContentControl Content="{StaticResource EndPath}" HorizontalAlignment="Left" RenderTransformOrigin="0.5,0.5" ContentTemplate="{StaticResource EndPath}">
                        <ContentControl.RenderTransform>
                            <TransformGroup>
                                <ScaleTransform ScaleX="1"/>
                                <SkewTransform/>
                                <RotateTransform Angle="180"/>
                                <TranslateTransform/>
                            </TransformGroup>
                        </ContentControl.RenderTransform>
                    </ContentControl>

                    <ContentControl Content="{StaticResource EndPath}" HorizontalAlignment="Right" RenderTransformOrigin="0.5,0.5" ContentTemplate="{StaticResource EndPath}" Width="14" Height="112" VerticalAlignment="Top">
                        <ContentControl.RenderTransform>
                            <TransformGroup>
                                <ScaleTransform ScaleX="1"/>
                                <SkewTransform/>
                                <RotateTransform Angle="0"/>
                                <TranslateTransform/>
                            </TransformGroup>
                        </ContentControl.RenderTransform>
                    </ContentControl>
                </Grid>
            </ControlTemplate>
        </Setter.Value>
    </Setter>
</Style>
</ResourceDictionary>